package cn.ad.server.domain.enumration;

import java.util.HashMap;
import java.util.Map;

/**
 * @author wang wei
 * @from 2016-05-23
 * @since V1.0
 */
public enum OS {

	/**
	 *  0 - 未知  1 - android 2 - ios  3- windows',
	 */
	UNKNOWN(0,"未知"),
    ANDROID(1,"android"),
	IOS(2,"ios"),
	WINDOWS(3,"windows");

    private int value;

    private String name;

    public static final Map<Integer, OS> osMap;

    static {
    	osMap = new HashMap<>();
        for (OS actionType : values()) {
        	osMap.put(actionType.getValue(), actionType);
        }
    }

    OS(int value, String name) {
        this.value = value;
        this.name = name;
    }

    public int getValue() {
        return value;
    }

    public String getName() {
        return name;
    }

}
